const NODE_ENV = process.env.NODE_ENV

export default {
  success: (title = '', url, data) => {
    if (NODE_ENV === 'development') {
      console.log(
        `%c✅${title ? title + ';\n' : ''}${url}\n;${JSON.stringify(data)}`,
        'color: white; background: green; font-weight: bold;'
      )
    }
  },
  fail: (title = '', url, data) => {
    if (NODE_ENV === 'development') {
      console.log(
        `%c❌${title ? title + ';\n' : ''}${url}\n;${JSON.stringify(data)}`,
        'color: white; background: red; font-weight: bold;'
      )
    }
  }
}
